import request from '@/utils/request'

// 查询风险防范体系列表
export function listAgainst(query) {
  return request({
    url: '/safe/against/list',
    method: 'get',
    params: query
  })
}

// 查询风险防范体系详细
export function getAgainst(rpsId) {
  return request({
    url: '/safe/against/' + rpsId,
    method: 'get'
  })
}

// 新增风险防范体系
export function addAgainst(data) {
  return request({
    url: '/safe/against',
    method: 'post',
    data: data
  })
}

// 修改风险防范体系
export function updateAgainst(data) {
  return request({
    url: '/safe/against',
    method: 'put',
    data: data
  })
}

// 删除风险防范体系
export function delAgainst(rpsId) {
  return request({
    url: '/safe/against/' + rpsId,
    method: 'delete'
  })
}

// 导出风险防范体系
export function exportAgainst(query) {
  return request({
    url: '/safe/against/export',
    method: 'get',
    params: query
  })
}